package cn.iocoder.an.module.business.dal.mysql.equipmentchecktype;

import java.util.*;

import cn.iocoder.an.framework.common.pojo.PageResult;
import cn.iocoder.an.framework.mybatis.core.query.LambdaQueryWrapperX;
import cn.iocoder.an.framework.mybatis.core.mapper.BaseMapperX;
import cn.iocoder.an.module.business.dal.dataobject.equipmentchecktype.EquipmentCheckTypeDO;
import org.apache.ibatis.annotations.Mapper;
import cn.iocoder.an.module.business.controller.admin.equipmentchecktype.vo.*;

/**
 * 点检项设置 Mapper
 *
 * @author zzy
 */
@Mapper
public interface EquipmentCheckTypeMapper extends BaseMapperX<EquipmentCheckTypeDO> {

    default PageResult<EquipmentCheckTypeDO> selectPage(EquipmentCheckTypePageReqVO reqVO) {
        return selectPage(reqVO, new LambdaQueryWrapperX<EquipmentCheckTypeDO>()
                .likeIfPresent(EquipmentCheckTypeDO::getName, reqVO.getName())
                .eqIfPresent(EquipmentCheckTypeDO::getStatus, reqVO.getStatus())
                .orderByDesc(EquipmentCheckTypeDO::getId));
    }

}